﻿using BackTask.Json;
using BackTask.Core.Builders;

namespace BackTask.Configurations.Builders
{
    public static class BaseTaskJobJsonBuilderExtension
    {
        public static TaskJobBuilder UseJsonFile(this TaskJobBuilder baseTaskJobBuilder, string fileName)
        {
            var configuration = new JsonConfiguration();
            configuration.UseConfiguration(fileName);
            baseTaskJobBuilder.UseTaskConfiguration(configuration);
            return baseTaskJobBuilder;
        }
    }
}
